package org.apache.dubbo;

import org.apache.dubbo.common.URL;
import org.apache.dubbo.common.context.Lifecycle;

public class CarWrapper implements Car, Lifecycle {

    private Car car;

    public CarWrapper(Car car){
        this.car = car;
    }
    @Override
    public String getCar(URL url) {
        System.out.println("调用前...");
        String s = this.car.getCar(url);
        System.out.println(s);
        System.out.println("调用后...");
        return s;
    }

    @Override
    public void test() {

    }

    @Override
    public void initialize() throws IllegalStateException {
        //System.out.println("inti....");
    }

    @Override
    public void start() throws IllegalStateException {

    }

    @Override
    public void destroy() throws IllegalStateException {

    }
}
